import request from '@/utils/request'

export function fetchRooms(query) {
  return request({
    url: '/room/list',
    method: 'get',
    params: query
  })
}
export function updateRoom(query) {
  return request({
    url: '/room/update',
    method: 'post',
    data: query
  })
}
export function removeRoom(query) {
  return request({
    url: '/room/remove',
    method: 'post',
    data: query
  })
}

const createRoom = process.env.VUE_APP_BASE_API + '/room/create'
export { createRoom }